% Software clustering algorithms group source code entities into modules, facilitating software architecture documentation. Empirical evaluation of the algorithms, however, is difficult because there are few software systems with reference clusterings for comparison with the clusterings found by algorithms. In this thesis we propose an approach based on models that generate graphs representing software systems with built-in reference clusterings. The approach is validated through an experiment that shows that the models produce graphs resembling the graph of static dependencies between classes in object oriented software systems. Finally, clustering algorithms are evaluated through model generated graphs. It is expected that this study will increase the available knowledge about clustering algorithms, which can contribute to their improvement in the future.

The analysis of dependencies between source code entities of a software system is performed by several reverse engineering tools in order to reveal information that is useful for software maintenance. There is, however, a shortage of experimental studies designed to evaluate such tools, in part due to the high cost of conducting experiments in the area.

In the area of networks and distributed systems, the high cost of experimentation motivates the use of simulation as a means to evaluate protocols and algorithms. In reverse engineering, however, simulations are underexplored --- which is partly explained by the lack of realistic computational models for dependencies between source code entities.

This paper presents computer models that generate representations which can be interpreted as dependencies between source code entities. One of the models, called BCR+, was developed in the context of this work. We have also developed a classification model that can tell, with accuracy of 96\%, whether a representation of dependencies is realistic --- that is, if it resembles representations extracted from real systems. %Then, we identified parameter settings for three computational models (among them, BCR+) that favor the generation of realistic representations of dependencies.

% This work presents three dependency models in order to support the evaluation of reverse engineering tools via controlled simulations. One of them, called BCR+, was developed in the context of this work. An evaluation of the models showed that, with an appropriate choice of parameters, they produce dependency networks that are structurally similar to dependencies extracted from real software systems. Moreover, classification rules were derived to predict, with 75\% accuracy, whether a network that was generated with certain parameter values will be similar to networks extracted from software systems.

This work also presents a proof of concept, demonstrating the feasibility of using BCR+ to evaluate algorithms used in the context of software architecture recovery, a branch of reverse engineering.
